<?php
	include_once("./global.php");
	session_start();
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" id="html">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
<title>后台首页</title>
</head>
<style>
	body{ background:#e7e7e7; margin:0; padding:0;}
	#container{ width:980px; height:auto; position:relative; margin:0 auto;}
	#container #header{ width:980px; height:90px; position:relative; background:#000; line-height:90px;color:#fff; font-size:24px; text-align:center;}
	.left{width:250px; height:auto; position:relative; float:left;}
	.left table{width:248px; height:auto; position:relative; float:left; background:#fff;}
	.left table td{ height:20px; text-align:center;}
	.left table .selected{ background:#73abe3;}
	#content{ width:730px; height:100%; position:relative; float:left; margin:2px 0px;}
	#content .title{ width:720px; height:25px; position:relative; float:left; line-height:25px; font-size:18px; color:#fff; background:#000;}
	form{margin:20px auto; width:720px; height:auto; position:relative; float:left;}
	form .inpuarea{ width:360px; height:150px;}
</style>
<body>
	<div id="container">
		<div id="header">
			818苹果站后台管理
            <span style="width:50px; height:25px; float:right; line-height:25px; position:absolute; top:65px; right:0px;font-size:14px;"><a href="admin_main.php?action=out">[登出]</a></span>
		</div>
		<div class="left">
			<table>
				<tr><td style="background:#000000; color:#fff;">站点管理</td></tr>
				<tr><td><a href="admin_site_mangerment.php">全局管理</a></td></tr>
				<tr><td>静态页面管理</td></tr>
				<tr><td><a href="admin_link_mangerment.php?page=1">友情链接管理</a></td></tr>
				<tr><td><a href="admin_member_mangerment.php?page=1">会员管理</a></td></tr>
				<tr><td><a href="admin_tags_mangerment.php?page=1">标签管理</a></td></tr>
				<tr><td><a href="admin_search_mangerment.php">搜索管理</a></td></tr>
			</table>
			<table>
				<tr><td style="background:#000000; color:#fff;">文章管理</td></tr>
				<tr><td><a href="admin_category_mangerment.php">文章分类管理</a></td></tr>
				<tr><td><a href="admin_news_add.php">发布文章</a></td></tr>
				<tr><td><a href="admin_news_mangerment.php?page=1">文章管理</a></td></tr>
			</table>
			<table>
				<tr><td style="background:#000000; color:#fff;">应用管理</td></tr>
				<tr><td><a href="admin_appcate_mangerment.php">应用分类管理</a></td></tr>
				<tr><td><a href="admin_app_add.php">添加应用</a></td></tr>
				<tr><td><a href="admin_app_mangerment.php?page=1">应用管理</a></td></tr>
				<tr><td><a href="admin_app_collection.php">应用采集</a></td></tr>
				<tr><td><a href="admin_app_collection_single.php">单应用采集</a></td></tr>
			</table>
		</div>
	</div>
   	<div id="content">
		<div class="title">发布文章</div>
        <table style="text-align:center; border:1px solid #000;">
        	<tr>
            	<td style="text-align:center; border:1px solid #000;">推广位编号</td>
            	<td style="text-align:center; border:1px solid #000;">推广位</td>
                <td style="text-align:center; border:1px solid #000;">APP/文章编号</td>
                <td style="text-align:center; border:1px solid #000;">图片编号</td>                
            </tr>
            <?php
            
				$sql_select_push = "select * from pushinfo";
				$query_select_push = $mysqli->query($sql_select_push);
				while($result_select_push = $query_select_push->fetch_assoc()){
			?>
            <tr>
            		<td style="text-align:center; border:1px solid #000;"><?php echo $result_select_push['P_Pushid'];?></td>
					<td style="text-align:center; border:1px solid #000;"><?php echo $result_select_push['P_Pushname'];?></td>
                    <td style="text-align:center; border:1px solid #000;"><?php if(!$result_select_push['P_Pushappid']){echo "文章编号".$result_select_push['P_Pushartid'];}else{echo "应用".$result_select_push['P_Pushappid'];}?></td>
                    <td style="text-align:center; border:1px solid #000;"><?php echo $result_select_push['P_Pushpid'];?></td>                   
			</tr>
			<?php
            	}			
			?>
            <tr>
            
            </tr>
        </table>
	</div>

</body>
<script>
/*	$(document).ready(function(){
		$("table").find("td").click(function(){
			src = $(this).attr("data-option-value");
			if(!$(this).hasClass("selected")){
				$("table").find("td").removeClass("selected");
				$(this).addClass("selected");
				$("iframe").attr("src",src);
			}			
		});
	});*/
	

</script>
</html>